export const dev_host = 'http://www.xwg.com'; // 开发环境域名
export const mock_host = 'http://mock.zhongbenruanjian.com'; // MOCK环境域名
export const product_host = 'https://api.anyuexinxi.com'; // 生产环境域名
export const WEBSOCKET = 'wss://zbphp.zhongbenzx.com/socket/';
export const PAAS_URL = 'https://test.anyuexinxi.com'; // paas域名
// export const PAAS_URL = 'https://yufabu.saizhuge.net'; // paas域名
export const IS_DEV = 3; // 0:生产环境 1:开发环境 2:mock环境 3:paas环境
export const PAGE_SIZE = 15; // 分页配置 每页条数
export const SERVER_TYPE = 0; // 服务端类型 0:赛诸葛  1  mock  2:其他
export const API_VERSION = 'm6748'; //APP接口版本号 正常是V1 使用paas  m加企业ID
export const INTERFACE_PREFIX = 'api'; //接口前缀
let _host = ''; // 自定义请求地址
if (!_host) {
	switch (IS_DEV) {
		case 0:
			_host = product_host
			break;
		case 1:
			_host = dev_host
			break;
		case 2:
			_host = mock_host
			break;
		case 3:
			_host = PAAS_URL
			break;
		default:
			break;
	}
}
//_host="";	//本地H5调试
export const host = _host; // 项目中接口地址host
export const SHAREURL = host + '/h5/#/'; // 分享的H5地址
export const SERIAL = ''; // 项目序列号(千万千万千万不要修改!!!!)
export const BenBenChooseFileKey = ''; // 文件选择原生插件key
export const BASE_URL = `${host}`; // 基础路径
export const API_BASE_URL = `${host}${INTERFACE_PREFIX ? '/' + INTERFACE_PREFIX : ''}`; // 接口请求基础路径
// export const STATIC_URL = '/static/images/';        // 静态资源目录
export const STATIC_URL = 'https://xiaoweigoumini.oss-cn-heyuan.aliyuncs.com/wechat/images/'; // 静态资源目录
export const IMG_BASE_URL = `${host}/upload/`; // 图片基础路径 公共filters assembleImgSrc依赖此配置
export const HOME_PAGE_URL = ["/pages/tabBar/login/login"] // 配置首页路由 主要用于跳转首页
// tabBar配置
export const tabbarConfig = []
// 主题色配置
export const themeColorConfig = [{
	"colorConfig": ["#333333", "#666666", "#999999", "#ffffff", "#FF8E21", "rgba(191, 191, 191, 1)",
		"#FC9C3A", "#4DC777", "#F2CC98", "#F2CC66"
	],
	"bgColorConfig": ["#FF8E21", "rgba(255, 255, 255, 1)", "rgba(246, 247, 249, 1)",
		"rgba(248, 248, 248, 1)", "rgba(153, 153, 153, 1)", "rgba(0, 82, 199, 1)", "rgba(26, 104, 64, 1)",
		"rgba(235, 104, 30, 1)", "rgba(27, 37, 64, 1)", "rgba(24, 144, 255, 1)"
	],
	"bdColorConfig": ["#f8f8f8", "#FFFFFF", "#FF8E21", "#FC9C3A", "#333333", "#666666", "#999999",
		"#ffffff", "#1178F0", "#F02325"
	]
}]
export const cartNumIndex = 2
// #ifdef APP-PLUS || H5
export const LOGIN_PAGE_URL = '/pages/tabBar/login/login' // 登录页面路由 request.js 依赖此配置 主要用于登录失效跳转
// #endif
// #ifdef MP-WEIXIN
export const LOGIN_PAGE_URL = '/pages/tabBar/login/login' // 登录页面路由 request.js 依赖此配置 主要用于登录失效跳转
// #endif
export const LANGUAGES = [{
	name: '中文 (简体)',
	value: 'zh-Hans'
}]; //语言包配置
let locale = uni.getLocale()
export const LOCALE = LANGUAGES.find(item => item.value == locale); //语言包配置
let _platform = uni.getSystemInfoSync().platform;
// #ifdef APP-PLUS
_platform = _platform === 'android' ? 'Android' : 'IOS';
// #endif
// #ifdef H5
_platform = 'Web';
// #endif
// #ifdef MP-WEIXIN
_platform = 'Wechat';
// #endif
// #ifdef MP-ALIPAY
_platform = 'Alipay';
// #endif
// #ifdef MP-BAIDU
_platform = 'Baidu';
// #endif
// #ifdef MP-TOUTIAO
_platform = 'ByteBounce';
// #endif
// #ifdef MP-360
_platform = '360';
// #endif
// #ifdef QUICKAPP-WEBVIEW
_platform = 'FastApp';
// #endif
export const ACCEPT_PLATFORM = _platform; //所属平台
export const SYSTEM_CONFIG = { // 系统配置
	logo: '/static/logo.png',
	appName: '校味购',
	appVersion: '1.0.0',
	platform: _platform,
}
export const needProductUrl = [];
// "/pages/inSchool/restaurant/restaurant", "/pages/inSchool/ctshopList/ctshopList", "/pages/index/searchye/searchye", "/pages/index/result/result",

const needPageUrl = ["/pages/index/price/price", "/pages/index/details/details",
	"/pages/index/centreCoupon/centreCoupon",  
	"/pages/index/newDetails/newDetails", "/pages/index/platform/platform",
	"/pages/index/orderMessage/orderMessage", "/pages/index/myNew/myNew", 
	 "/pages/inSchool/dpDetails/dpDetails",
	"/pages/inSchool/shopSearch/shopSearch", "/pages/inSchool/dpResult/dpResult", "/pages/inSchool/report/report",
	"/pages/inSchool/sjQualific/sjQualific", "/pages/inSchool/spDetails/spDetails",
	"/pages/inSchool/allEvaluae/allEvaluae", "/pages/inSchool/settlement/settlement",
	"/pages/inSchool/xzCoupon/xzCoupon", "/pages/inSchool/addNotes/addNotes", "/pages/inSchool/cashier/cashier","/pages/inSchool/cashier/lakala",
	"/pages/inSchool/yePay/yePay", "/pages/inSchool/payResult/payResult", "/pages/release/release/release",
	"/pages/release/notes/notes", "/pages/release/cyAddress/cyAddress", "/pages/release/informatio/informatio",
	"/pages/order/detailsDd/detailsDd", "/pages/order/refundXq/refundXq", "/pages/order/delayed/delayed",
	"/pages/order/evaluate/evaluate", "/pages/order/evaluateCg/evaluateCg", "/pages/order/sqRefund/sqRefund",
	"/pages/order/legDdXq/legDdXq", "/pages/order/ptEvaluate/ptEvaluate", "/pages/order/errandsSh/errandsSh",
	"/pages/my/myInfo/myInfo", "/pages/my/myOrder/myOrder", "/pages/my/wallet/wallet",
	"/pages/my/balanceDetails/balanceDetails", "/pages/my/recharge/recharge", "/pages/my/czSuccess/czSuccess",
	"/pages/my/myCoupon/myCoupon", "/pages/my/myCollect/myCollect", "/pages/my/myReview/myReview",
	"/pages/my/addressManagement/addressManagement", "/pages/my/addAddress/addAddress",
	"/pages/my/editAddress/editAddress", "/pages/my/riderRz/riderRz", "/pages/my/Rzrider/Rzrider",
	"/pages/my/revieweds/revieweds", "/pages/userSet/helpDetails/helpDetails",
	"/pages/userSet/helpFeedback/helpFeedback", "/pages/userSet/feedBack/feedBack", "/pages/userSet/system/system",
	"/pages/riderSet/seup/seup"
];
const defNeedLoginPage = [
	"/pages/user/address/address-list/index",
	"/pages/user/address/address-add/index",
	"/pages/index/setting/change-pay-password/index",
	"/pages/index/setting/modify-pay-password/index",
	"/pages/index/setting/change-password/index",
	"/pages/service-mssage/message/message-list/index",
	"/pages/user/user/info/index",
	"/pages/user/user/avatar-cropping/index",
	"/pages/index/setting/setting/index",
	"/pages/index/setting/feedback/index",
	"/pages/index/setting/my-feedback/index",
	"/pages/index/setting/verify-oldphone/index",
	"/pages/index/setting/change-newphone/index",
	"/pages/user/wallet/my-wallet/index",
	"/pages/user/wallet/consumer-detail/index",
	"/pages/user/wallet/recharge/index",
	"/pages/user/wallet/recharge-log/index",
	"/pages/user/wallet/withdraw/index",
	"/pages/user/wallet/withdraw-success/index",
	"/pages/user/wallet/account-bind/index",
	"/pages/user/wallet/alipay-bind/index",
	"/pages/user/wallet/wechat-bind/index",
	"/pages/user/user/my-favorites/index",
	"/pages/user/user/my-footprint/index",
	"/pages/order/afterorder/afterorder-apply/index",
	"/pages/order/afterorder/afterorder-status-list/index",
	"/pages/order/afterorder/afterorder-detail/index",
	"/pages/order/afterorder/afterorder-sendback/index",
	"/pages/order/order-process/confirm-order/index",
	"/pages/order/order-process/pay-order/index",
	"/pages/order/order-process/pay-success/index",
	"/pages/order/order-process/choos_coupon/index",
	"/pages/order/order-list/all-order/index",
	"/pages/order/orderdetail/order-detail/index",
	"/pages/order/orderdetail/express-delivery/index",
	"/pages/order/evaluation/order-evaluation/index",
	"/pages/news/article/article-favoriters/index",
	"/pages/goods/ask-answer/my-ask-answer/index",
	"/pages/service-message/message/message-type/index",
	"/pages/user/coupon/my-coupon/index",
	"/pages/integral/myintegral/my-integral/index",
	"/pages/distribution/distribution/my-distribution/index",
	"/pages/service-message/service/service-detail/index",
	"/pages/user/invite/user-invite/index",
	"/pages/index/setting/modify-password-verify-phone/index",
	"/pages/index/setting/modify-password/index",
]
let needLoginPage = defNeedLoginPage;
if (Array.isArray(needPageUrl)) {
	needLoginPage = defNeedLoginPage.concat(needPageUrl);
}

export const needLoginPages = needLoginPage;
